1. Field of the Invention
The present invention generally relates to an Open Systems Gateway Initiative (OSGi) bundle, and more specifically to an OSGi bundle dynamically created with sophisticated logic that can dynamically adapt to specific runtime environments and underlying operating systems.
2. Description of the Related Art
OSGi technology is the dynamic module system for the Java programming language. OSGi applications, called bundles, are defined by OSGi framework which standardizes the OSGi platform. OSGi is based on bundles that provide or use functionality. OSGi allows installing/uninstalling and starting/stopping through the bundles.
However, a problem with the conventional OSGi framework is that all dependencies and exported functionality need to be manifested inside a bundle. Because of this, an OSGi bundle might have different dependencies based on an operating system running on a specific machine. Different dependencies also may be based on specific OSGi framework implementations existing in the machine (for example, Common Agent Services (CAS) framework requires additional logging). Also, different dependencies may be based on specific software installed on the machine.
The OSGi standard requires that all required dependencies and all native code be specified in the bundle manifest, which has to be put in the bundle—which makes it impossible to use native code based on machine specific details. As all dependencies and all native code need to be specified in the bundle manifest, it is difficult to use different pieces of native code based on the present hardware specific details.